<?php

namespace App\Http\Controllers;

//use App\Models\Traits\WordFilter;
use Illuminate\Http\Request;
use App\Http\Controllers\FilterController as Filter;

class HomeController extends Controller
{


    //
    public function getWxPay()
    {
        return view('wxPay');
    }


    public function filter( )
    {


         $bad_word = Filter::getBadWord('');

//         dd($bad_word);

        if (!empty($bad_word)) {
//            throw new \Exception('包含敏感词:' . current($bad_word));
            return '包含敏感词:'.current($bad_word);
        }
    }
}
